<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<title></title>
		<!--标准mui.css-->
		<link rel="stylesheet" href="../../css/mui.min.css">
		<!--App自定义的css-->
		<link rel="stylesheet" type="text/css" href="../../css/app.css" />
		<!--<link href="../css/mui.picker.css" rel="stylesheet" />
		<link href="../css/mui.dtpicker.css" rel="stylesheet" />-->
		<link rel="stylesheet" type="text/css" href="../../css/mui.picker.min.css" />
		<script src="../../js/getURLParam.js"></script>
		<link rel="stylesheet" href="../../css/global.css">
		<style>
			html,
			body,
			.mui-content {
				height: 0px;
				margin: 0px;
				background-color: #efeff4;
			}
			
			h5.mui-content-padded {
				margin-left: 3px;
				margin-top: 20px !important;
			}
			
			h5.mui-content-padded:first-child {
				margin-top: 12px !important;
			}
			
			.mui-btn {
				font-size: 16px;
				padding: 8px;
				margin: 3px;
			}
			
			.ui-alert {
				text-align: center;
				padding: 20px 10px;
				font-size: 16px;
			}
			
			* {
				-webkit-touch-callout: none;
				-webkit-user-select: none;
			}
		</style>
	</head>

	<body>
		<header class="mui-bar mui-bar-nav headerstyle">
			<a class="mui-action-back astyle"><img src="../../images/drawable-hdpi/head_back.png"/></a>
			<h1 class="mui-title">日工作时间分布</h1>
		</header>
		<div class="mui-content">
			<div class="mui-content-padded">
				<div id="worktimedis">
					<!--<div style="width:720px;" id="null1" ><img title="在00:00:00到23:59:59处于关机状态" src="./images/dayWorkTime/time_no.gif" width="720"  height="10"/></div>-->
				</div>
			</div>
			<!--<div style="width: 400px;height: 400px;text-align: center;">
				  <iframe style="border: hidden;width: 900px;height: 900px;zoom: 50%;" scrolling="auto" src="" id="dutycycle"></iframe></div>-->
		</div>
		<script src="../../js/mui.min.js"></script>
		<script src="../../js/mui.picker.min.js"></script>
		<script>
		mui.init();
			var sessionid=GetQueryString("sessionid");
			var accountid=GetQueryString("accountid");
	        var proversion=GetQueryString("proversion");
	        var vclnum = GetQueryString("vclno");
	        var nowdate = new Date();
	        nowdate.setDate(nowdate.getDate()-1);
	        var worktimedis = document.getElementById("worktimedis");
	        var month = (nowdate.getMonth()+1)>=10?(nowdate.getMonth()+1):"0"+(nowdate.getMonth()+1);
	        var dtime=nowdate.getFullYear()+"-"+month+"-"+nowdate.getDate();
	        var con="";
	        var content="";
	        mui.ajax('../../../APPIOS/workTimeDis', {
				data: {
					param: '{"proVersion":"' + proversion + '","accountId":"' + accountid + '","sessionid":"' + sessionid + '","data":{"vclnum":"'+vclnum+'","dtime":"' + dtime + '","orgCode":""}}'
				},
				dataType: 'jsonp', //服务器返回json格式数据
				type: 'post', //HTTP请求类型
				timeout: 10000, //超时时间设置为10秒；
				success: function(data) {
					var jsonObj = window.JSON.parse(data);
					if (jsonObj.resultcode == "1") {
						 worktimedis.innerHTML=jsonObj.resultcode;
						//获取返回数据的data
						var resultdata = jsonObj.data;
						if (null != resultdata) {
							for(var i=0;i<resultdata.length;i++){
								con=resultdata[i].imgStr;
								var reg=/\\/g;//替换字符串中的反斜杠
								con = con.replace(reg,"");
								content+="<div>"+resultdata[i].VehicleNumber+":"+con+"</div>";
							}
							worktimedis.innerHTML=content;
						} else {
							//document.getElementById("dd").value="ff";
							worktimedis.innerHTML="暂无数据";
						}
			
					} else {
						worktimedis.innerHTML="请求错误："+jsonObj.resultcode;
					}
				},
				error: function(xhr, type, errorThrown) {
				}
			});
		</script>
	</body>

</html>